This should fix the missing option '--output-path' on webpack.#1627
This should fix the missing option '--output-path' on webpack.#1627TheLarkInn merged 3 commits intoangular:masterfrom
Conversation
60e4753 to
2950339
Compare
|
@not-only-code can you update your branch with master. |
200af15 to
9db0591
Compare
|
@TheLarkInn updated. |
| let webpackCompiler: any; | ||
|
|
||
| var config: NgCliWebpackConfig = new NgCliWebpackConfig(this.project, commandOptions.target, commandOptions.environment).config; | ||
| var config: NgCliWebpackConfig = new NgCliWebpackConfig(this.project, commandOptions.target, commandOptions.environment, commandOptions.outputPath).config; |
There was a problem hiding this comment.
Content base property for webpack dev server needs to be set also. This I believe is pulled in from webpack-build-utils or is set when that object is pulled into the serve task.
There was a problem hiding this comment.
After some research, I saw that setting up contentBase in 'webpack-dev-server' configuration does not bundle the files into the desired folder. So i did use this plugin write-file-webpack-plugin which forces 'webpack-dev-server' to write a bundle folder.
Now ng serve will always output a bundle files (dist/ by default) as system.js did in previous versions.
9db0591 to
8ed71ce
Compare
|
We do not want files emitted for serve. webpack-dev-server serves virtual bundles in memory. Setting content base just ensures that the dev server is point to the correct 'virtual output path' to know how to emulate the output files. |
8ed71ce to
8526ae5
Compare
|
Ok, reverted last changes, just added |
|
Otherwise you might as well be using ng build with watch flag and additional server setup. In memory fs is really an important build performance feature in this case. |
|
Perfect no worries and yay for tests we like that!!!! |
8794962 to
7cb6919
Compare
7cb6919 to
2af0551
Compare
|
Updated. |
|
LGTM. |
|
Thank you! @not-only-code |
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Previous PR to
webpackbranch: #1595Related issue: #1569